package com.blog.backend.config;

import com.alibaba.fastjson.JSONObject;
import com.blog.backend.model.EquipInfo;
import org.springframework.integration.annotation.MessagingGateway;
import org.springframework.integration.mqtt.support.MqttHeaders;
import org.springframework.messaging.handler.annotation.Header;
 
@MessagingGateway(defaultRequestChannel = "mqttOutboundChannel")
public interface MqttGateway {

    void sendToMqtt(String data,@Header(MqttHeaders.TOPIC) String topic);
    void sendToMqtt(EquipInfo data, @Header(MqttHeaders.TOPIC) String topic);
}